<?

  ob_start();
  header('content-type: text/html; charset=utf-8');
  profile_point('- page start');

?><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <base href="<?= $config['site.base'] ?>">
    <meta http-equiv="content-type" content="text/html; charset=utf-8">
    <link type="text/css" rel="stylesheet" href="themes/bl4cksun/default.css"/>
    <title><?= $doctitle ?></title>
	<?= implode(' ', $config['pageheaders']) ?>
  </head>
  <body>
    <table align="center" width="800" height="100%" 
      cellspacing="0" cellpadding="0"><tr><td class="content" valign="top">
      <img src="themes/bl4cksun/logo1.png"/><br/>
      <div class="menubar">
        <? 
        foreach ($config['menu'] as $item) { ?><a href="<?= $item['url'] ?>"><?= $item['caption'] ?></a><? } ?>
        <? 
        foreach ($config['accountmenu'] as $item) { ?><a href="<?= $item['url'] ?>"><?= $item['caption'] ?></a><? } ?>
        <span class="menuclose"></span>
      </div>
      <div class="content-text">
      <!--<h1>
        <?= $doctitle ?>
      </h1>-->
      <?= utf8_encode($content) ?>
      </div>
    </td></tr></table>
  </body>
</html><?
 
  profile_point('- end');
  print(ob_get_clean());
  profile_point('- write out buffer');
?>
